package com.tuanzi.loan.business.service.statistics.impl;

import com.tuanzi.loan.business.repository.statistics.UnionLoginStatRepository;
import com.tuanzi.loan.business.repository.statistics.WechatAccountRepository;
import com.tuanzi.loan.business.service.statistics.WechatAccountService;
import com.tuanzi.loan.core.aspect.Debug;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.statistics.WechatAccountRequest;
import com.tuanzi.loan.vo.response.statistics.WechatAccountResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.retry.RetryException;
import org.springframework.retry.annotation.Retryable;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * @Auther: hequnayu
 * @Date: 2019/5/14 14:23
 * @Description:
 */
@Debug
@Service
@Transactional
@Retryable(value = { RetryException.class })
public class WechatAccountServiceImpl implements WechatAccountService {

    @Autowired
    private WechatAccountRepository wechatAccountRepository;

    @Override
    public Page<WechatAccountResponse> list(PageSearcher<WechatAccountRequest> pageSearcher) {
        return wechatAccountRepository.list(pageSearcher.getSearchCondition(), pageSearcher.getPageable());
    }
}
